package com.mini.mysql.service;

import com.mini.mysql.model.BusinessBaseSubInfo;
import com.mini.mysql.repository.BusinessBaseSubInfoRepository;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 项目名称：mini-data-es
 * 类 名 称：BusinessLessonInfoService
 * 类 描 述：TODO
 * 创建时间：2021/4/1 下午6:43
 * 创 建 人：zhanghuiying
 */
@Service
@Slf4j
public class BusinessBaseSubInfoService {

    @Autowired
    private BusinessBaseSubInfoRepository businessBaseSubInfoRepository;

    public List<BusinessBaseSubInfo> findBaseSub(List<Long> ids){
        if (CollectionUtils.isEmpty(ids)){
            return null;
        }
       return businessBaseSubInfoRepository.findBaseSub(ids);
    }
}
